The sleep dataset shows the effect of two soporific drugs (increase in hours of sleep compared to control) on 10 students.
| extra | group | ID |
|---|---|---|
| 0.7 | 1 | 1 |
| -1.6 | 1 | 2 |
| -0.2 | 1 | 3 |
| -1.2 | 1 | 4 |
| -0.1 | 1 | 5 |
| 3.4 | 1 | 6 |
April 23, 2019
The sleep dataset shows the effect of two soporific drugs (increase in hours of sleep compared to control) on 10 students.
| extra | group | ID |
|---|---|---|
| 0.7 | 1 | 1 |
| -1.6 | 1 | 2 |
| -0.2 | 1 | 3 |
| -1.2 | 1 | 4 |
| -0.1 | 1 | 5 |
| 3.4 | 1 | 6 |
library(plotly) plot_ly(sleep, y = ~extra, color = ~group, type = "box")
plot_ly(sleep, x= ~ID, y = ~extra, color = ~group, type = "scatter")